package guoanmaker.provider.business.repository;


import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;

import guoanmaker.provider.business.model.ProvideRoom;
import guoanmaker.provider.business.model.ProviderBusiness;

import java.util.List;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

import guoanmaker.provider.business.model.ProvideCommodity;
import guoanmaker.provider.business.model.ProvideRoom;

public interface ProvideRoomRepository extends JpaRepository<ProvideRoom, String>,JpaSpecificationExecutor<ProvideRoom>{

	 @Query("select pm from ProvideRoom pm where pm.roomState=:roomState")
	 public List<ProvideRoom> selectRoomListStauts(@Param("roomState") Integer roomState);
	 
	 public ProvideRoom findByIdIsAndRoomStateIs(String id,Integer state);
}
